import type { I_Config } from './type'
import {
  AuthEntity,
  CategoryEntity,
  PostCommentEntity,
  PostEntity,
  RoleEntity,
  UploadEntity,
  UserEntity
} from '../entitys'

export const production: I_Config = {
  port: parseInt(process.env.PORT, 10) || 3000,
  DATABASE_CONFIG: {
    type: 'sqlite',
    database: 'data/prod-sqlite.db',
    entities: [
      AuthEntity,
      CategoryEntity,
      PostCommentEntity,
      PostEntity,
      RoleEntity,
      UploadEntity,
      UserEntity
    ],
    synchronize: true,
    logger: 'file',
    logging: ['error', 'log', 'query']
  }
}
